package com.gs.zsmanage.dao;

import com.gs.zsmanage.entity.CustomWarning;
import com.gs.zsmanage.vo.IdAndName;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface CustomWarningMapper {

    //SELECT t1.*,t2.department FROM t_warning t1 right join (SELECT warning_id,department FROM t_custom_warning WHERE department = '') t2 on t1.id = t2.warning_id
    List<CustomWarning> listCustomWarningByDepartment(String department);

    //select * from t_warning
    List<IdAndName> listAllWarning();

    void addCustomWarning(@Param("department") String department, @Param("warningId") Integer warningId);

    void deleteCustomWarning(@Param("department") String department, @Param("warningId") Integer warningId);

}
